<?php
//后台路由
$admin = array(
    'namespace' => 'Admin',
    'middleware' => ['web']
);

Route::group($admin, function () {
    // 登录
    Route::controller('login', 'Login' . CTR);

    Route::any('center/shop/charge-notify', 'ShopController@anyChargeNotify');
    Route::get('center', 'LoginController@getIndex');

    Route::group(['prefix' => 'center', 'middleware' => 'checkAdminlogin'], function () {
        /**
         * 隐式控制器路由组
         */
        Route::controllers([
            'test' => 'Test' . CTR,
            'index' => 'Index' . CTR,
            'admin' => 'Admin' . CTR,
            'action' => 'Action' . CTR,
            'article' => 'Article' . CTR,
            'auth' => 'Auth' . CTR,
            'config' => 'Config' . CTR,
            'menu' => 'Menu' . CTR,
            'database' => 'Database' . CTR,  //数据备份还原
            'file' => 'File' . CTR,
            'shop' => 'Shop' . CTR,
            'goods' => 'Goods' . CTR,
            'bucket' => 'Bucket' . CTR,
            'shop-goods' => 'ShopGoods' . CTR,
            'goods-category' => 'GoodsCategory' . CTR,
            'bucket-category' => 'BucketCategory' . CTR,
            'brand' => 'Brand' . CTR,
            'waterbill' => 'WaterBill' . CTR,
            'waterbill-category' => 'WaterBillCategory' . CTR,
            'shop-waterbill-category' => 'ShopWaterBillCategory' . CTR,
            'wechat' => 'Wechat' . CTR,
            'order' => 'Order' . CTR,
            'worker' => 'Worker' . CTR,
            'member' => 'Member' . CTR,
            'single' => 'Single' . CTR,
            'channel' => 'Channel' . CTR,
            'service' => 'Service' . CTR,
            'waterbill-order' => 'WaterBillOrder' . CTR,
            'peripheral' => 'Peripheral' . CTR,
            'notify-log' => 'NotifyLog' . CTR,
            'statistic' => 'Statistic'. CTR,
            'sao-pay' => 'SaoPay'.CTR,
        ]);
    });

});
